home *** CD-ROM | disk | FTP | other *** search
/ OpenGL Superbible (2nd Edition) / OpenGL SuperBible e2.iso / tools / GLUT-3.7 / LINUX / Glut.cf next >
Encoding:
Text File  |  1998-08-12  |  7.1 KB  |  153 lines

  1. XCOMM Copyright (c) Mark J. Kilgard, 1994, 1997, 1998.
  2. XCOMM Glut.cf - GLUT distribution Imakefile configuration info
  3.  
  4. XCOMM Modifications made to accomidate for use with Brian Paul's Mesa.
  5. XCOMM Peter F. Martone
  6.  
  7. #ifndef MathLibrary /* introduced with X11R6 */
  8. #define MathLibrary -lm
  9. #endif
  10.  
  11. #ifndef SaberProgramTarget /* in X11R5 but removed in X11R6 */
  12. #define SaberProgramTarget(program,srclist,objlist,locallibs,syslibs)
  13. #endif
  14.  
  15. #ifdef SunArchitecture
  16.  
  17. /*
  18.  * Solaris has a non-standard way of placing libraries
  19.  * and header files.  This should work for Template Graphics Systems'
  20.  * OpenGL implementation, assuming your OGLHOME and OPENWINHOME
  21.  * environment variables are set correctly.
  22.  */
  23. EXTRA_INCLUDES = -I$(TOP)/include -I$(OGLHOME)/include -I$(OPENWINHOME)/include
  24. OPENGL = -L$(OGLHOME)/lib -lGL -L$(OPENWINHOME) -ldga
  25. GLU = -L$(OGLHOME)/lib -lGLU
  26. /* XXX Is this right, Template?? */
  27. INVENTOR = -L$(OGLHOME)/lib -lInventor
  28. GLUT_DEPLIBS = $(DEPGLUT) $(DEPXMULIB) $(DEPXILIB) $(DEPXLIB)
  29. GLUT_LIBS = $(GLUT) $(GLU) $(OPENGL) $(XMULIB) $(XILIB) $(XLIB) MathLibrary
  30. MUI_DEPLIBS = $(DEPMUI) $(DEPGLUT) $(DEPXMULIB) $(DEPXILIB) $(DEPXLIB)
  31. MUI_LIBS = $(MUI) $(GLUT) $(GLU) $(OPENGL) $(XMULIB) $(XILIB) $(XLIB) MathLibrary
  32. GLE_DEPLIBS = $(DEPGLE) $(DEPGLUT) $(DEPXMULIB) $(DEPXILIB) $(DEPXLIB)
  33. GLE_LIBS = $(GLE) $(GLUT) $(GLU) $(OPENGL) $(XMULIB) $(XILIB) $(XLIB) MathLibrary
  34. GLSMAP_DEPLIBS = $(DEPGLSMAP) $(DEPGLUT) $(DEPXMULIB) $(DEPXILIB) $(DEPXLIB)
  35. GLSMAP_LIBS = $(GLSMAP) $(GLUT) $(GLU) $(OPENGL) $(XMULIB) $(XILIB) $(XLIB) MathLibrary
  36.  
  37. #else /* Everybody but Sun... */
  38. #ifdef AlphaArchitecture
  39.  
  40. /* Alpha suggestions from Andrej Panjkov (mataap@pop.latrobe.edu.au). */
  41.  
  42. /* Andrej writes:  There is a bug in one of the imake configuration
  43.    files supplied with Digital Unix 3.2c that will cause the build to
  44.    fail.  In the file /usr/lib/X11/config/osflib.tmpl, the reference to
  45.    libXi.a should be changed to libXi.so   (which is in the correct
  46.    directory /usr/shlib).  Root access is needed to fix this bug.  I
  47.    don't know if the bug persists in later versions of DU. */
  48.  
  49. #if 0 /* Not using now. */
  50. /*
  51.  * Digital puts all Imake symbols for use with OpenGL in OpenGL.tmpl, so use
  52.  * the contents of that file instead of the definitions here.
  53.  */
  54. #include <OpenGL.tmpl>
  55. EXTRA_INCLUDES = GLUTInclude
  56. #else
  57. EXTRA_INCLUDES = -I$(TOP)/include
  58. #endif
  59.  
  60. INVENTOR = -lInventor
  61.  
  62. /* Suggested by Andrej Panjkov (mataap@pop.latrobe.edu.au) */
  63. DEPGLUTLIB = $(TOP)/lib/glut/libglut.a
  64. GLUTLIB = $(TOP)/lib/glut/libglut.a
  65.  
  66. GLUT_LIBS =       $(GLUTLIB)    $(GLULIB)    $(GLLIB)    $(XMULIB) $(XILIB) $(XLIB) MathLibrary
  67. GLUT_DEPLIBS = $(DEPGLUTLIB) $(DEPGLULIB) $(DEPGLLIB) $(DEPXMULIB) $(DEPXILIB) $(DEPXLIB)
  68. MUI_LIBS =       $(MUI) $(GLUTLIB)    $(GLULIB)    $(GLLIB)    $(XMULIB) $(XILIB) $(XLIB) MathLibrary
  69. MUI_DEPLIBS = $(DEPMUI) $(DEPGLUTLIB) $(DEPGLULIB) $(DEPGLLIB) $(DEPXMULIB) $(DEPXILIB) $(DEPXLIB)
  70. GLE_LIBS =       $(GLE) $(GLUTLIB)    $(GLULIB)    $(GLLIB)    $(XMULIB) $(XILIB) $(XLIB) MathLibrary
  71. GLE_DEPLIBS = $(DEPGLE) $(DEPGLUTLIB) $(DEPGLULIB) $(DEPGLLIB) $(DEPXMULIB) $(DEPXILIB) $(DEPXLIB)
  72. GLSMAP_LIBS =       $(GLSMAP) $(GLUTLIB)    $(GLULIB)    $(GLLIB)    $(XMULIB) $(XILIB) $(XLIB) MathLibrary
  73. GLSMAP_DEPLIBS = $(DEPGLSMAP) $(DEPGLUTLIB) $(DEPGLULIB) $(DEPGLLIB) $(DEPXMULIB) $(DEPXILIB) $(DEPXLIB)
  74.  
  75. #else /* Everybody but Sun or DEC Alpha... */
  76.  
  77. /*
  78.  * This should work for normal vendors that put their OpenGL and X
  79.  * libraries and headers in standard places (or at least where
  80.  * imake configuration files know where they are).
  81.  */
  82.  
  83. #ifdef HPArchitecture
  84. /* Nate Robbins (E&S) reports that HP does not have its Xmu.h header in
  85.    the standard place. */
  86. XMU_HEADERS = /usr/contrib/X11R5/include/
  87. EXTRA_INCLUDES = -I$(TOP)/include -I$(XMU_HEADERS)
  88. #else
  89. EXTRA_INCLUDES = -I$(TOP)/../include -I$(TOP)/include /* modified per Mesa README PFM 6/31/96 */
  90. #endif
  91.  
  92. GLUT_DEPLIBS = $(DEPGLUT) $(DEPXMULIB) $(DEPXLIB)
  93. GLUT_LIBS = $(GLUT) $(GLU) $(OPENGL) $(XMULIB) $(XLIB) MathLibrary
  94. OPENGL = $(TOP)/../lib/libMesaGL.so /* modified per Mesa README PFM 6/31/96 */
  95. GLU = $(TOP)/../lib/libMesaGLU.so /* modified per Mesa README PFM 6/31/96 */
  96. INVENTOR = -lInventor
  97. GLUT_DEPLIBS = $(DEPGLUT) $(DEPXMULIB) $(DEPXILIB) $(DEPXLIB)
  98. GLUT_LIBS = $(GLUT) $(GLU) $(OPENGL) $(XMULIB) $(XILIB) $(XLIB) MathLibrary
  99. MUI_DEPLIBS = $(DEPMUI) $(DEPGLUT) $(DEPXMULIB) $(DEPXILIB) $(DEPXLIB)
  100. MUI_LIBS = $(MUI) $(GLUT) $(GLU) $(OPENGL) $(XMULIB) $(XILIB) $(XLIB) MathLibrary
  101. GLE_DEPLIBS = $(DEPGLE) $(DEPGLUT) $(DEPXMULIB) $(DEPXILIB) $(DEPXLIB)
  102. GLE_LIBS = $(GLE) $(GLUT) $(GLU) $(OPENGL) $(XMULIB) $(XILIB) $(XLIB) MathLibrary
  103. GLSMAP_DEPLIBS = $(DEPGLSMAP) $(DEPGLUT) $(DEPXMULIB) $(DEPXILIB) $(DEPXLIB)
  104. GLSMAP_LIBS = $(GLSMAP) $(GLUT) $(GLU) $(OPENGL) $(XMULIB) $(XILIB) $(XLIB) MathLibrary
  105.  
  106. #endif
  107. #endif
  108.  
  109. #ifndef AlphaArchitecture
  110. DEPGLUT = $(TOP)/lib/glut/libglut.so /* modified to make so's PFM 6/31/96 */
  111. GLUT = $(TOP)/lib/glut/libglut.so /* modified to make so's PFM 6/31/96 */
  112. #endif
  113. DEPMUI = $(TOP)/lib/mui/libmui.a
  114. MUI = $(TOP)/lib/mui/libmui.a
  115. DEPGLE = $(TOP)/lib/gle/libgle.a
  116. GLE = $(TOP)/lib/gle/libgle.a
  117. DEPGLSMAP = $(TOP)/lib/glsmap/libglsmap.a
  118. GLSMAP = $(TOP)/lib/glsmap/libglsmap.a
  119.  
  120. CXXEXTRA_INCLUDES = -I/usr/include/CC $(EXTRA_INCLUDES)
  121. GLUT_INVENTOR_DEPLIBS = $(GLUT_DEPLIBS)
  122. GLUT_INVENTOR_LIBS = $(INVENTOR) $(GLUT_LIBS)
  123.  
  124. #ifdef SGIArchitecture
  125. /* For SGI C++ compiler, need to search extra dirs in make depend */
  126. #undef CplusplusDependIncludes
  127. #define CplusplusDependIncludes -I$(ROOT)/usr/include/CC
  128. #endif
  129.  
  130. #ifndef NullParameter
  131. /*
  132.  * NullParameter should be #define'ed to nothing in Imake.rules, but it has
  133.  * been reported to me that this is not always the case.  If not, let
  134.  * Glut.cf #define it to nothing.
  135.  */
  136. #define NullParameter
  137. #endif
  138.  
  139. #define GlutTestProgramTarget(name) NormalProgramTarget(name,name.o,$(GLUT_DEPLIBS),$(GLUT_LIBS),NullParameter)
  140. #define MuiTestProgramTarget(name) NormalProgramTarget(name,name.o,$(MUI_DEPLIBS),$(MUI_LIBS),NullParameter)
  141. #define SimpleGlutProgramTarget(name) NormalProgramTarget(name,name.o,$(GLUT_DEPLIBS),$(GLUT_LIBS),NullParameter)
  142. #define NormalGlutProgramTarget(name,objs) NormalProgramTarget(name,objs,$(GLUT_DEPLIBS),$(GLUT_LIBS),NullParameter)
  143. #define SimpleMuiProgramTarget(name) NormalProgramTarget(name,name.o,$(MUI_DEPLIBS),$(MUI_LIBS),NullParameter)
  144. #define NormalMuiProgramTarget(name,objs) NormalProgramTarget(name,objs,$(MUI_DEPLIBS),$(MUI_LIBS),NullParameter)
  145. #define SimpleGleProgramTarget(name) NormalProgramTarget(name,name.o,$(GLE_DEPLIBS),$(GLE_LIBS),NullParameter)
  146. #define NormalGleProgramTarget(name,objs) NormalProgramTarget(name,objs,$(GLE_DEPLIBS),$(GLE_LIBS),NullParameter)
  147. #define SimpleGlsmapProgramTarget(name) NormalProgramTarget(name,name.o,$(GLSMAP_DEPLIBS),$(GLSMAP_LIBS),NullParameter)
  148. #define NormalGlsmapProgramTarget(name,objs) NormalProgramTarget(name,objs,$(GLSMAP_DEPLIBS),$(GLSMAP_LIBS),NullParameter)
  149. #define SimpleGlutInventorProgramTarget(name) NormalCplusplusProgramTarget(name,name.o,$(GLUT_INVENTOR_DEPLIBS),$(GLUT_INVENTOR_LIBS),NullParameter)
  150. #define NormalGlutInventorProgramTarget(name,objs) NormalCplusplusProgramTarget(name,objs,$(GLUT_INVENTOR_DEPLIBS),$(GLUT_INVENTOR_LIBS),NullParameter)
  151.  
  152. XCOMM end Glut.cf - GLUT distribution Imakefile configuration info
  153.